using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class UpgradeSlugger:Upgrade {

	int count;

	protected override void ShootingEventHandler(object _sender,ShootEventArgs e) {
		base.ShootingEventHandler(_sender,e);
		if(!IfReactWeaponEvent(_sender,e)) return;

		Weapon sender = _sender as Weapon;
		count=(int)e.stat.projectileCount;
		e.stat.projectileCount=1;
	}


	protected override void ProjectileFiringEventHandler(object _sender,ProjectileEventArgs e) {
		base.ProjectileFiringEventHandler(_sender,e);
		if(!IfReactProjectileEvent(_sender,e)) return;
		e.stat.damage.AddMultiply(count,2);
		e.stat.size.AddMultiply(Mathf.Sqrt(count),2);
		count=1;
	}

}
